package com.itheima.stringbuilder;

public class StringBuliderDemo2 {
    public static void main(String[] args) {
       StringBuilder sb =new StringBuilder();
       //append()表示追加,括号里面参数可以是任意类型的数据
        sb.append("死亡如风");
        sb.append("常伴吾身");
        System.out.println(sb);

        //reverse()代表反转
        sb.reverse();
        System.out.println(sb);

        //toString()代表转成字符串类型,返回值是字符串对象
         String sb1 = sb.toString();

    }
}
